<template>
  <div>
    <button @click="getStuInfo">获取学生信息</button>
  </div>
</template>

<script>
import axios from "axios";
export default {
  name: 'App',
  methods:{
    getStuInfo(){
      axios.get('http://localhost:8080/students').then(response=>{
            console.log('成功了',response.data)
          },
      error=>{
        console.log(error.message)
      })
    },
  }
}
</script>
